package org.hawk.gwtppc.webtest.tests.miscsuite;

import java.lang.reflect.Modifier;

import org.hawk.gwtppc.webtest.common.Asserts;
import org.hawk.gwtppc.webtest.common.Test;
import org.hawk.gwtppc.webtest.tests.mock.InnerClassesMock;

import com.google.gwt.core.client.GWT;
import com.google.gwt.event.dom.client.ClickEvent;

public class NativeMethodTest implements Test {

	public void run() throws Throwable {
		if (!GWT.isScript() || !GWT.isClient()) {
			Asserts.skip("Not applicable for dev mode");
		}
		Asserts.assertEquals(InnerClassesMock.class.getDeclaredMethod("fireEvent", ClickEvent.class).getModifiers(),
				Modifier.PUBLIC | Modifier.NATIVE);
	}

	public String getName() {
		return "testNativeMethods()";
	}

}
